Repository navigation
docs(ui): a contributed navigation entry's order sorts it among the target app's own entries - #33472
objectstack-fleet[bot] wants to merge 1 commit into
Conversation
…arget app's own entries The navigationContributions section named only group and priority. The fold (SchemaRegistry.applyNavContributions) appends a contribution's items as authored, order included, and the console sorts every level by order afterwards (ui/packages/layout/src/navOrder.ts byNavOrder: the top level, each group's children, the mobile tab bar; pinned by ui/packages/layout/src/__tests__/AppSchemaRenderer.mobileTabOrder-11395.test.tsx). Say so, with the consequences: no order sorts as 0, ties keep the fold's sequence so priority only breaks ties, and the host must number its own entries for a contribution to land between them. Pin the objectql half beside the group-semantics cases: the fold keeps a contributed item's order (and appends it after the host's entries) in a group and at the top level, and writes no order onto an item that has none. Claude-Session: https://claude.ai/code/session_01FEkQ5pRMxnBBFzFztXjepS Co-Authored-By: Claude <noreply@anthropic.com>
📓 Docs Drift CheckNothing in this diff resolved to a documentable surface (no symbol, route or SDK anchor derived from 0 changed package(s)), so this run has no opinion about the docs. What this run could not see
Coarse fallback — 0 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): |
|
domain:spec#1 · os-project-manager · session_01FEkQ5mswnWm181XgYcCUag ACCEPT · PR #33472 (#33447) · head
|
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 43657223386 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 43659594732 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
Requested by Leehom · project thread
domain:spec#1 · os-project-manager · session_01FEkQ5pRMxnBBFzFztXjepS
Fixes #33447
Clause-②: no
Metadata-protocol: none
维护者速读
content/docs/ui/apps.mdx的「向其他应用贡献导航」一节补一段话、示例加一个order: 30;导航条目表的order行补半句「其他包贡献的条目也在同一层参与排序」。另在 objectql 现有的导航贡献测试文件里加 3 条钉子,钉住合并时贡献条目的order原样保留。group和priority,下游以为模块的条目只能排在应用自有条目之后。实际上合并原样保留order,控制台按order排每一层,所以order: 25会排在应用的 20 和 30 之间,前提是应用给自己的条目编了号。这是 app nav: a per-audience landing (and group placement) cannot name an entry contributed by a module package — so an industry module can never be a role's landing page or reorder past the app's own groups #33234 裁定 C(不改)后留给文档的缺口。content/docs/ui/apps.mdxL863 起的新段落;packages/objectql/src/registry-nav-contribution-group-semantics.test.tsL509 起的新describe。pnpm --filter @objectstack/objectql exec vitest run src/registry-nav-contribution-group-semantics.test.ts,预期 13 条全绿(原 10 条 + 新 3 条)。What changes
content/docs/ui/apps.mdx, thenavigationContributionssection (L863). One paragraph: the merge appends a contribution's items to the end of their group (or the top level) as written,orderincluded; the console then sorts each level byorder(the top level, each group's children, the mobile tab bar), soorder: 25is drawn between the app's own20and30. Noordersorts as0; equalorderkeeps the merged sequence, soprioritydecides only between contributions whose items have the sameorder; the target app has to number its own entries, otherwise a contribution stays after them. The example'snav_webhooksitem gainsorder: 30(L847).orderrow (L297). One clause: entries contributed by another package sort in the same level, linking to the section.packages/objectql/src/registry-nav-contribution-group-semantics.test.ts, new top-leveldescribe(L509), beside the existing group/priority propositions in the same harness file: a host app that numbers its entries plus contributor modules, installed as one artifact through the manifest service, read withregistry.getApp.sales_groupchildren read[nav_accounts, 10], [nav_contacts, 30], [nav_cpq, 20]: appended, not sorted in,orderuntouched.[nav_home, 10], [sales_group, 20], [nav_reports, 30], [nav_forecast, 25].orderhas noorderkey after the fold, in a group or at the top level.What the code does, read on
origin/main19cc8976before writing:SchemaRegistry.applyNavContributions(packages/objectql/src/registry.tsL11003) pushesc.itemsinto the group'schildren(L11024) or the top level (L11034 relocation, L11037 no group) with no map or sort; the console's one comparator isbyNavOrderinui/packages/layout/src/navOrder.ts((a.order ?? 0) - (b.order ?? 0), stable sort), used atNavigationRenderer.tsxL2113 (top level) and L1797 (a group's children) andAppSchemaRenderer.tsxL327 (mobile tab bar). That comparator is pinned byui/packages/layout/src/__tests__/AppSchemaRenderer.mobileTabOrder-11395.test.tsx; this PR does not re-test it.No source line moves, nothing in
packages/specchanges, no new key, nobefore/after, no landing on a contributed entry (#33234 ruled C, record 6884379643).Tests
Ablation (head
5357d88d,scripts/ablation-replace.mjsonpackages/objectql/src/registry.ts, each anchor 1 → 0, replacement 0 → 1; the test imports./registry.jsand./plugin.jsfromsrc/, no dist in the path):Three mutations of the fold, each red; restored blob 85ef55a712f7 == HEAD, 13 passed
Acceptance notes
content/docs/ui/apps.mdxis incheck:skill-examples' docs root, but only fences under anos:checkmarker are type-checked; the page has 4 marked fences and thenavigationContributionsexample fence is not one of them, so no snippet type-check runs on the edited block. The new in-page link#contributing-navigation-to-another-appis read bycheck:doc-anchors(exit 0).skip-changeset.@objectstack/objectqlshipsfiles: [dist, README.md, CHANGELOG.md]; a*.test.tsis not in its build, andcontent/docs/**is in no package. No published byte moves.Verification
On head
5357d88d(branchclaude/project-thread-dn0u43, merge baseorigin/main19cc8976), each exit code captured before any pipe:pnpm --filter @objectstack/objectql exec vitest run --maxWorkers=2(the package'slocalproject, under the verify lock): exit 0, Test Files 596 passed (596), Tests 13005 passed (13005).pnpm --filter @objectstack/objectql typecheck(tsc --noEmitpluscheck:test-typecheckovertsconfig.test.json, which compiles the test layer): exit 0, "39 file(s) / 233 error(s) / 64 pinned signature(s) held", no new signature.eslint --no-inline-configon the test file: exit 0.node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack, 81 families): 80 exit 0;pnpm check:dual-build-cjs-loadsexit 3 PREREQUISITE NOT MET (needs every package'sdist/), NOT MEASURED, CI runs it. Three families first answered exit 3 on prerequisites and were rerun green after clearing them:check-plugin-teardown-shape.mjs --self-test(fixture commit fetched),check:skill-examples(client and client-react built; "344 prose examples type-check across 3 surface(s)"),check:lean-entry-closure(objectql built).--ran: "81 derived famil(ies) accounted for — 80 run, 1 NOT-MEASURED".dispatch-gates --tier: no path-derived mandate. 135 changed lines, under the 3000 threshold. No governed surface.🤖 Generated with Claude Code
https://claude.ai/code/session_01FEkQ5pRMxnBBFzFztXjepS